package main

import (
	"LC3Go/vm"
	"fmt"
	"os"
	"strings"
)

func main() {
	if len(os.Args) < 2 || len(strings.TrimSpace(os.Args[1])) == 0 {
		fmt.Println("no input file!")
		return
	}
	var rom = os.Args[1]
	_, err := os.Stat(rom)
	if os.IsNotExist(err) {
		fmt.Printf("file %s not found!\n", rom)
		return
	}
	vm.Run(rom)
}
